package com.yunxi.model.freeze;

import com.baomidou.mybatisplus.annotation.*;
import com.fasterxml.jackson.databind.annotation.JsonDeserialize;
import com.yunxi.core.web.DateJsonDeserializer;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;

import java.io.Serializable;
import java.math.BigDecimal;
import java.util.Date;

/**
 * <p>
 * 渠道商帐户
 * </p>
 *
 * @author 
 * @since 2019-05-20
 */
@Data
@EqualsAndHashCode(callSuper = false)

@TableName("pms_partner_account")
@ApiModel(value="PartnerAccount对象", description="渠道商帐户")
public class PartnerAccount implements Serializable {

    private static final long serialVersionUID = 1L;

    @ApiModelProperty(value = "主键ID")
    @TableId(value = "ACCOUNT_ID", type = IdType.UUID)
    private String accountId;

    @ApiModelProperty(value = "帐户代码")
    @TableField("ACCOUNT_CODE")
    private String accountCode;

    @ApiModelProperty(value = "帐户名称")
    @TableField("ACCOUNT_NAME")
    private String accountName;

    @ApiModelProperty(value = "渠道商代码")
    @TableField("PARTNER_CODE")
    private String partnerCode;

    @ApiModelProperty(value = "帐户类型")
    @TableField("ACCOUNT_TYPE_CODE")
    private String accountTypeCode;

    @ApiModelProperty(value = "帐户总额")
    @TableField("ACCOUNT_AMOUNT")
    private BigDecimal accountAmount;

    @ApiModelProperty(value = "帐户余额")
    @TableField("ACCOUNT_BALANCE")
    private BigDecimal accountBalance;

    @ApiModelProperty(value = "创建时间")
    @JsonDeserialize(using = DateJsonDeserializer.class)
    @TableField(value ="CREATE_TIME",fill = FieldFill.INSERT)
    private Date createTime;

    @ApiModelProperty(value = "创建人")
    @TableField("CREATE_BY")
    private String createBy;

    @ApiModelProperty(value = "修改时间")
    @JsonDeserialize(using = DateJsonDeserializer.class)
    @TableField(value ="UPDATE_TIME", fill = FieldFill.UPDATE)
    private Date updateTime;

    @ApiModelProperty(value = "修改人")
    @TableField("UPDATE_BY")
    private String updateBy;

    @ApiModelProperty(value = "状态1启用0禁用")
    @TableField("STATUS")
    private Integer status;

    @ApiModelProperty(value = "是否删除")
    @TableField("IS_DEL")
    private Integer isDel;

    @ApiModelProperty(value = "备注")
    @TableField("MEMO")
    private String memo;

    @ApiModelProperty(value = "授信配置")
    @TableField("CREDIT_ID")
    private String creditId;

    @ApiModelProperty(value = "是否返利账户Y是N否")
    @TableField("IS_REBATE")
    private String isRebate;

    @ApiModelProperty(value = "冻结资金")
    @TableField("FROZEN_AMOUNT")
    private BigDecimal frozenAmount;
}
